* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: linear-gradient(to right, #0f2027, #203a43, #2c5364);
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: #fff;
}

.player {
    width: 100%;
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: flex-end; /* 修改为底部对齐 */
    align-items: center;
    /* background-color: rgba(0, 0, 0, 0.5); */
    border-radius: 10px;
    padding: 20px;
    margin: 0;
    position: relative; /* 添加相对定位 */
}

.player-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    margin-bottom: 10px;
}

.player-controls .controls {
    display: flex;
    align-items: center;
}

.player-cover {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background-color: #000;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    margin-bottom: 20px;
}

.player-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.player-info {
    margin-bottom: 20px;
}

.player-info h1 {
    font-size: 32px;
    margin-bottom: 10px;
}

.player-info p {
    font-size: 16px;
}

.player-controls .controls button {
    background-color: transparent;
    border: none;
    cursor: pointer;
    font-size: 24px;
    color: #fff;
    margin-right: 10px;
}

.player-controls .controls button:hover {
    color: #ddd;
}

.player-controls .progress-bar {
    flex: 1;
    height: 5px;
    background-color: #555;
    border-radius: 5px;
    overflow: hidden;
    margin: 0 10px;
    cursor: pointer;
}

.player-controls .progress-bar .progress {
    width: 0;
    height: 100%;
    background-color: #00ff00;
    transition: width 0.3s;
}

.playlist {
    width: 300px; /* 设置播放列表的宽度 */
    max-width: 300px;
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 10px;
    padding: 20px;
    position: absolute; /* 绝对定位 */
    top: 0;
    right: -8px; /* 初始位置在右边隐藏 */
    height: 100%;
    transition: right 0.3s; /* 平滑过渡效果 */
    overflow-y: auto; /* 如果内容超出高度，显示滚动条 */
}

.playlist h2 {
    margin-bottom: 10px;
}

.playlist ul {
    list-style: none;
}

.playlist li {
    padding: 10px;
    border-bottom: 1px solid #555;
    cursor: pointer;
}

.playlist li:hover {
    background-color: #444;
}

.toggle-playlist {
    background-color: transparent;
    border: none;
    cursor: pointer;
    font-size: 24px;
    color: #fff;
    margin-right: 10px;
}

.toggle-playlist:hover {
    color: #ddd;
}